package com.java1234.service.impl;

import com.java1234.dao.LeaveDao;
import com.java1234.entity.Leave;
import com.java1234.service.LeaveService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;
@SuppressWarnings("ALL")
@Service
public class LeaveServiceImpl implements LeaveService{

    @Autowired
    LeaveDao leaveDao;


    @Override
    public List<Leave> find(Map<String, Object> map) {
        return leaveDao.find(map);
    }

    @Override
    public Long getTotal(Map<String, Object> map) {
        return leaveDao.getTotal(map);
    }

    @Override
    public int add(Leave leave) {
        return leaveDao.add(leave);
    }

    @Override
    public Leave findById(Integer id) {
        return leaveDao.findById(id);
    }

    @Override
    public int update(Leave leave) {
        return leaveDao.update(leave);
    }
}
